<template>
  <div class="nav-wrapper">
    <div class="bar-title">肉桂大数据平台</div>
    <div class="navList">
      <button
        v-for="(navItem, index) in navList"
        :key="index"
        class="button type1"
        @click="nav(navItem.path)"
      >
        {{ navItem.title }}
      </button>
    </div>
  </div>
</template>

<script>
export default {
  data() {
    return {
      navList: [
        {
          title: '返回',
          path: '/bigdata-home'
        },
      ],
    }
  },
  methods: {
    nav(path) {
      this.curPath = path
      this.$router.replace(path)
    }
  }
}
</script>

<style lang="scss" scoped>
.nav-wrapper {
  height: 65px;
  line-height: 50px;
  width: 100%;
  background: url("../img/nav.png") no-repeat;
  background-size: 100% 100%;
  text-align: center;
  position: relative;

  .bar-title {
    color: #ffffff;
    font-size: 1.7rem;
    font-family: "黑体";
    cursor: pointer;
  }
}
.return {
  position: absolute;
  top: 0%;
  left: 5%;
}
.navList {
  position: absolute;
  top: 20%;
  right: 1%;
}

.button {
  position: relative;
  padding: 0.3em 1.3em;
  border: none;
  background-color: transparent;
  cursor: pointer;
  outline: none;
  font-size: 16px;
  margin: 0em 0.8em;
}
.button.type1 {
  font-weight: bold;
  color: #00ffff;
}
.button.type1.type1::after,
.button.type1.type1::before {
  content: "";
  display: block;
  position: absolute;
  width: 20%;
  height: 20%;
  border: 2px solid;
  transition: all 0.6s ease;
  border-radius: 2px;
}
.button.type1.type1::after {
  bottom: 0;
  right: 0;
  border-top-color: transparent;
  border-left-color: transparent;
  border-bottom-color: #00ffff;
  border-right-color: #00ffff;
}
.button.type1.type1::before {
  top: 0;
  left: 0;
  border-bottom-color: transparent;
  border-right-color: transparent;
  border-top-color: #00ffff;
  border-left-color: #00ffff;
}
.button.type1.type1:hover:after,
.button.type1.type1:hover:before {
  width: 100%;
  height: 100%;
}
</style>
